package com.example.friend.service.impl;


import com.example.common.core.domain.TableDataInfo;
import com.example.friend.domain.exam.dto.ExamQueryDTO;
import com.example.friend.domain.exam.dto.ExamRankDTO;
import com.example.friend.domain.exam.vo.ExamVO;
import com.example.friend.mapper.exam.ExamMapper;
import com.example.friend.service.IExamService;
import com.github.pagehelper.PageHelper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;


import java.util.List;


@Service
@Slf4j
public class IExamServiceImpl implements IExamService {

    @Autowired
    private ExamMapper examMapper;

    @Override
    public List<ExamVO> list(ExamQueryDTO examQueryDTO) {
        PageHelper.startPage(examQueryDTO.getPageNum(), examQueryDTO.getPageSize());
        return examMapper.selectExamList(examQueryDTO);
    }

    @Override
    public Long total(ExamQueryDTO examQueryDTO) {
        return examMapper.total(examQueryDTO);
    }

    @Override
    public TableDataInfo redisList(ExamQueryDTO examQueryDTO) {
        return null;
    }

    @Override
    public TableDataInfo rankList(ExamRankDTO examRankDTO) {
        return null;
    }

    @Override
    public String getFirstQuestion(Long examId) {
        return null;
    }

    @Override
    public String preQuestion(Long examId, Long questionId) {
        return null;
    }

    @Override
    public String nextQuestion(Long examId, Long questionId) {
        return null;
    }
}
